package RW;

public class Rect {
	//2-4
	double len;
	double width;
	public Rect() {
	}
	public Rect(double len, double width) {
		super();
		this.len = len;
		this.width = width;
	}
	public double getArea() {
		return len*width;
	}
	@Override
	public String toString() {
		return String.format("矩形 [长=%.2f,宽=%.2f,面积=%.2f]",
				+ this.len,this.width,this.getArea());
	}
	
}
